<!DOCTYPE html>
<html lang="es">
    <head>
        <base href="/publicidad/"/>
        <meta charset="utf-8" />
        <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
        <meta name="description" content="">
        <meta name="author" content="">
        <link rel="shortcut icon" href="favicon.ico" />

        <title>WeOkey.net | Administrador</title>

        <!-- Bootstrap core CSS -->
        <link href="web/css/bootstrap.css" rel="stylesheet">

        <!-- Add custom CSS here -->
        <link href="web/css/sb-admin.css" rel="stylesheet">
        <link rel="stylesheet" href="web/font-awesome/css/font-awesome.min.css">
        <link href="web/css/bootstrapValidator.css" rel="stylesheet">

        <!-- Page-Level Plugin CSS - Tables -->
        <link href="web/css/plugins/dataTables/dataTables.bootstrap.css" rel="stylesheet">

        <!-- Page Specific CSS -->
        <!--<link rel="stylesheet" href="http://cdn.oesmith.co.uk/morris-0.4.3.min.css">-->

        <!-- JavaScript -->
        <script src="web/js/jquery-1.10.2.js"></script>
        <script src="web/js/bootstrap.js"></script>
        <script src="web/js/validator/bootstrapValidator.min.js"></script>
    </head>

    <body>

        <div id="wrapper">

            <!-- Sidebar -->
            <nav class="navbar navbar-inverse navbar-fixed-top" role="navigation">
                <!-- Brand and toggle get grouped for better mobile display -->
                <div class="navbar-header">
                    <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-ex1-collapse">
                        <span class="sr-only">Toggle navigation</span>
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                    </button>
                    <a class="navbar-brand hidden-xs" href="inicio">Gestión de Publicidad | Administrador</a>
                    <a class="navbar-brand visible-xs" href="inicio">Administrador</a>
                </div>

                <!-- Collect the nav links, forms, and other content for toggling -->
                <div class="collapse navbar-collapse navbar-ex1-collapse">
                    <ul class="nav navbar-nav side-nav">
                        <li><a href="inicio"><i class="fa fa-dashboard"></i> Inicio</a></li>
                        <li><a href="listado_comerciales"><i class="fa fa-suitcase"></i> Comerciales</a></li>
                        <li><a href="listado_clientes"><i class="fa fa-users"></i> Clientes</a></li>
                        <li><a href="listado_anuncios"><i class="fa fa-edit"></i> Anuncios</a></li>
                        <li><a href="listado_tarifas"><i class="fa fa-money"></i> Tarifas</a></li>
                        <li><a href="listado_sitios"><i class="fa fa-globe"></i> Sitios</a></li>
                        <li><a href="#" data-toggle="modal" data-target="#modalScript"><i class="fa fa-code"></i> Script</a></li>
                        <!--<li class="dropdown">
                            <a href="#" class="dropdown-toggle" data-toggle="dropdown"><i class="fa fa-caret-square-o-down"></i> Dropdown <b class="caret"></b></a>
                            <ul class="dropdown-menu">
                                <li><a href="#">Dropdown Item</a></li>
                                <li><a href="#">Another Item</a></li>
                                <li><a href="#">Third Item</a></li>
                                <li><a href="#">Last Item</a></li>
                            </ul>
                        </li>-->
                    </ul>

                    <ul class="nav navbar-nav navbar-right navbar-user">
                        <li class="dropdown user-dropdown">
                            <a href="#" class="dropdown-toggle" data-toggle="dropdown"><i class="fa fa-user"></i> <?php echo $_SESSION['weokey_publicidad_usuario_nombre']; ?><b class="caret"></b></a>
                            <ul class="dropdown-menu">
                                <li><a href="perfil"><i class="fa fa-user"></i> Perfil</a></li>
                                <li class="divider"></li>
                                <li><a href="logout"><i class="fa fa-power-off"></i> Cerrar Sesión</a></li>
                            </ul>
                        </li>
                    </ul>
                </div><!-- /.navbar-collapse -->
            </nav>
            <div id="page-wrapper">
                <?php echo $contenido ?>
            </div><!-- /#page-wrapper -->

        </div><!-- /#wrapper -->
        <!-- Modal -->
        <div class="modal fade" id="modalScript" tabindex="-1" role="dialog" aria-labelledby="modalScript" aria-hidden="true">
            <div class="modal-dialog">
                <div class="modal-content">
                    <div class="modal-header">
                        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                        <h4 class="modal-title" id="myModalLabel">Script Publicidad</h4>
                    </div>
                    <div class="modal-body">
                        <div class="highlight">
                            <code class="js">
                                <pre>
&lt;script>
    window.onload = function() {
        var x = document.createElement("IFRAME");
        x.setAttribute('frameborder', '0');
        x.setAttribute('scrolling', 'no');
        var host = window.location.hostname;
        var host = host.split('.')[0];
        var ln = window.navigator.language || navigator.browserLanguage;
        //alert(ln);
        x.setAttribute("src", "http://localhost/publicidad/ver_banner/host:" + host);
        document.getElementById('player').appendChild(x);
    }
&lt;/script>
                                </pre>
                            </code>

                        </div>
                    </div>
                    <div class="modal-footer">
                        <button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
                    </div>
                </div>
            </div>
        </div>



        <!-- Page Specific Plugins -->
        <!--<script src="http://cdnjs.cloudflare.com/ajax/libs/raphael/2.1.0/raphael-min.js"></script>
        <script src="http://cdn.oesmith.co.uk/morris-0.4.3.min.js"></script>-->
        <script src="web/js/tablesorter/jquery.tablesorter.js"></script>
        <script src="web/js/tablesorter/tables.js"></script>
        <script src="web/js/plugins/metisMenu/jquery.metisMenu.js"></script>

        <!-- Page-Level Plugin Scripts - Tables -->
        <script src="web/js/plugins/dataTables/jquery.dataTables.js"></script>
        <script src="web/js/plugins/dataTables/dataTables.bootstrap.js"></script>

        <!-- Page-Level Demo Scripts - Tables - Use for reference -->
        <script>
                $(document).ready(function() {
                    $('#dataTables-example').dataTable({
                        //"order": [[3, "desc"]]
                    });
                });

        </script>
    </body>
</html>